package com.test;

/**
 * @author likai
 * @date 2021/11/4 9:40 AM
 * @email likai9376@163.com
 * @desc
 */
public class B {


    public String getPrint(){
        return "我是B";
    }

    public static void main(String[] args) {
        A a = new A(new B()){
            {};

            @Override
            public String getPrin() {
                return super.getPrin();
            }
        };


        System.out.println(a.getPrin());
    }
}
